<#include "../common/_layout.html"/>
<@head title="">
<style type="text/css">
    .cll {
        background-color: #ddd;
    }
</style>
</@head>
<@layout menu='/wxuser'>
<!-- Content Header (Page header) -->
<section class="content-header">
    <h1>
        舟山汇智智能科技有限公司
    </h1>
    <ol class="breadcrumb">
        <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
        <li><a href="#">lte</a></li>
        <li class="active">prj</li>
    </ol>
</section>

<!-- Main content -->
<section class="content">
    <div class="row">
        <div class="col-xs-12">
            <div class="box">
                <form action="${ctx}/wxuser" id="listForm" method="post" role="form">
                    <input type="hidden" id="id" name="id" value="${id!}">
                    <input type="hidden" id="errcode" name="errcode" value="${errcode!}">
                    <div class="box-header">
                        <h3 class="box-title">${wx.name!}关注的用户</h3>
                        <div class="box-tools">
                            <div class="input-group" style="width: 300px;">
                                <input type="text" name="prjName" id="prjName" class="form-control input-sm pull-right"
                                       placeholder="根据昵称查询" value="${prjName!}">
                                <div class="input-group-btn">
                                    <button class="btn btn-sm btn-default"><i class="fa fa-search"></i></button>
                                </div>
                            </div>
                        </div>
                    </div><!-- /.box-header -->
                    <div class="box-body table-responsive no-padding">
                        <button type="button" id="deleteButton" disabled="disabled" class="btn btn-default"
                                onclick="deleteAll('${ctx}/wxuser/delete')">删除
                        </button>
                        <button type="button" id="addOldButton"  class="btn btn-default"
                                onclick="location.href='${ctx}/wxuser/addOld?id=${id!}'">获取
                        </button>
                        <table class="table table-hover">
                            <tr class="info">
                                <th title=""><input type="checkbox" id="allCheck"></th>
                                <th hidden="hidden" title="openid">openid</th>
                                <th title="昵称">昵称</th>
                                <th title="性别">性别</th>
                                <th title="语言">语言</th>
                                <th title="城市">城市</th>
                                <th title="省份">省份</th>
                                <th title="国籍">国籍</th>
                                <th title="图片信息">图片信息</th>
                                <th title="关注时间">关注时间</th>
                                <th title="备注">备注</th>
                            </tr>
                            <#list page.getList() as item>
                                <tr>
                                    <td><input type="checkbox" name="ids" value="${item.id!}"></td>
                                    <td hidden>${item.openid!}</td>
                                    <td>${item.nickname!}</td>
                                    <td>
                                        <#if item.sex??&&item.sex==0>未知</#if>
                                    	<#if item.sex??&&item.sex==2>女</#if>
                                    	<#if item.sex??&&item.sex==1>男</#if>
                                    <td>${item.language!}</td>
                                    <td>${item.city!}</td>
                                    <td>${item.province!}</td>
                                    <td>${item.country!}</td>
                                    <td><img src="${item.headimg!}" height="50" width="50"></td>
                                    <td>${item.times!}</td>
                                    <td>${item.remark!}</td>
                                </tr>
                            </#list>
                        </table>
                        <#if (page.list?size>0)>
                        <#include "../common/pager.html">
                        </#if>
                    </div>
                </form>
            </div>
        </div>
    </div>
    <div class="row">
		<div class="col-xs-12">
			<button type="submit" class="btn btn-cancle"
				onclick="location.href='${ctx}/wechatinfo'">返回</button>
		</div>
	</div>
</section>
</@layout>
<@scripts>
<script type="text/javascript" src="${ctx}/adminlte/plugins/bootbox/bootbox.min.js"></script>
<script type="text/javascript" src="${ctx}/js/list.js"></script>
<script type="text/javascript">
    $(document).ready(function () {
        if($('#errcode').val()!=null && $('#errcode').val()!=""){
            alert("发生错误,获取失败！错误代码："+$('#errcode').val());
            document.getElementById("errcode").value= null;
        }
    });
</script>  
</@scripts>